<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration {
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('sendlogs', function (Blueprint $table) {
            $table->id();
            $table->integer('person_id')->nullable()->comment('联系人ID');
            $table->string('phone')->comment('手机号');
            $table->string('content')->comment('短信内容');
            $table->tinyInteger('status')->default(0)->comment('发送状态');
            $table->tinyInteger('is_used')->default(0)->comment('是否使用');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('sendlogs');
    }
};
